/**
 */
package org.xtext.context.aware.eventX.util;

import org.eclipse.emf.ecore.EObject;
import org.eclipse.emf.ecore.EPackage;

import org.eclipse.emf.ecore.util.Switch;

import org.xtext.context.aware.eventX.*;

/**
 * <!-- begin-user-doc -->
 * The <b>Switch</b> for the model's inheritance hierarchy.
 * It supports the call {@link #doSwitch(EObject) doSwitch(object)}
 * to invoke the <code>caseXXX</code> method for each class of the model,
 * starting with the actual class of the object
 * and proceeding up the inheritance hierarchy
 * until a non-null result is returned,
 * which is the result of the switch.
 * <!-- end-user-doc -->
 * @see org.xtext.context.aware.eventX.EventXPackage
 * @generated
 */
public class EventXSwitch<T> extends Switch<T>
{
  /**
   * The cached model package
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @generated
   */
  protected static EventXPackage modelPackage;

  /**
   * Creates an instance of the switch.
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @generated
   */
  public EventXSwitch()
  {
    if (modelPackage == null)
    {
      modelPackage = EventXPackage.eINSTANCE;
    }
  }

  /**
   * Checks whether this is a switch for the given package.
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @parameter ePackage the package in question.
   * @return whether this is a switch for the given package.
   * @generated
   */
  @Override
  protected boolean isSwitchFor(EPackage ePackage)
  {
    return ePackage == modelPackage;
  }

  /**
   * Calls <code>caseXXX</code> for each class of the model until one returns a non null result; it yields that result.
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @return the first non-null result returned by a <code>caseXXX</code> call.
   * @generated
   */
  @Override
  protected T doSwitch(int classifierID, EObject theEObject)
  {
    switch (classifierID)
    {
      case EventXPackage.CONTEXT_AWARE_MODEL:
      {
        ContextAwareModel contextAwareModel = (ContextAwareModel)theEObject;
        T result = caseContextAwareModel(contextAwareModel);
        if (result == null) result = defaultCase(theEObject);
        return result;
      }
      case EventXPackage.ELEMENT:
      {
        Element element = (Element)theEObject;
        T result = caseElement(element);
        if (result == null) result = defaultCase(theEObject);
        return result;
      }
      case EventXPackage.TIME_TABLE:
      {
        TimeTable timeTable = (TimeTable)theEObject;
        T result = caseTimeTable(timeTable);
        if (result == null) result = caseElement(timeTable);
        if (result == null) result = defaultCase(theEObject);
        return result;
      }
      case EventXPackage.DATE:
      {
        Date date = (Date)theEObject;
        T result = caseDate(date);
        if (result == null) result = defaultCase(theEObject);
        return result;
      }
      case EventXPackage.WEEK_DAY_TIME:
      {
        WeekDayTime weekDayTime = (WeekDayTime)theEObject;
        T result = caseWeekDayTime(weekDayTime);
        if (result == null) result = defaultCase(theEObject);
        return result;
      }
      case EventXPackage.TIME:
      {
        Time time = (Time)theEObject;
        T result = caseTime(time);
        if (result == null) result = defaultCase(theEObject);
        return result;
      }
      case EventXPackage.EVENT:
      {
        Event event = (Event)theEObject;
        T result = caseEvent(event);
        if (result == null) result = caseElement(event);
        if (result == null) result = defaultCase(theEObject);
        return result;
      }
      case EventXPackage.EVENT_TYPE:
      {
        EventType eventType = (EventType)theEObject;
        T result = caseEventType(eventType);
        if (result == null) result = defaultCase(theEObject);
        return result;
      }
      case EventXPackage.BASIC_EVENT:
      {
        BasicEvent basicEvent = (BasicEvent)theEObject;
        T result = caseBasicEvent(basicEvent);
        if (result == null) result = caseEventType(basicEvent);
        if (result == null) result = defaultCase(theEObject);
        return result;
      }
      case EventXPackage.CONDITIONAL_EVENT:
      {
        ConditionalEvent conditionalEvent = (ConditionalEvent)theEObject;
        T result = caseConditionalEvent(conditionalEvent);
        if (result == null) result = caseEventType(conditionalEvent);
        if (result == null) result = defaultCase(theEObject);
        return result;
      }
      case EventXPackage.ROOM_EVENT:
      {
        RoomEvent roomEvent = (RoomEvent)theEObject;
        T result = caseRoomEvent(roomEvent);
        if (result == null) result = caseBasicEvent(roomEvent);
        if (result == null) result = caseEventType(roomEvent);
        if (result == null) result = defaultCase(theEObject);
        return result;
      }
      case EventXPackage.CLOSE_BY:
      {
        CloseBy closeBy = (CloseBy)theEObject;
        T result = caseCloseBy(closeBy);
        if (result == null) result = caseBasicEvent(closeBy);
        if (result == null) result = caseEventType(closeBy);
        if (result == null) result = defaultCase(theEObject);
        return result;
      }
      case EventXPackage.TRANSITION_AREA:
      {
        TransitionArea transitionArea = (TransitionArea)theEObject;
        T result = caseTransitionArea(transitionArea);
        if (result == null) result = caseBasicEvent(transitionArea);
        if (result == null) result = caseEventType(transitionArea);
        if (result == null) result = defaultCase(theEObject);
        return result;
      }
      case EventXPackage.EVENT_ATTRIBUTES:
      {
        EventAttributes eventAttributes = (EventAttributes)theEObject;
        T result = caseEventAttributes(eventAttributes);
        if (result == null) result = defaultCase(theEObject);
        return result;
      }
      case EventXPackage.ACTION:
      {
        Action action = (Action)theEObject;
        T result = caseAction(action);
        if (result == null) result = caseElement(action);
        if (result == null) result = defaultCase(theEObject);
        return result;
      }
      case EventXPackage.SIMPLE_ACTION:
      {
        SimpleAction simpleAction = (SimpleAction)theEObject;
        T result = caseSimpleAction(simpleAction);
        if (result == null) result = caseAction(simpleAction);
        if (result == null) result = caseElement(simpleAction);
        if (result == null) result = defaultCase(theEObject);
        return result;
      }
      case EventXPackage.SEQUENTIAL_ACTION:
      {
        SequentialAction sequentialAction = (SequentialAction)theEObject;
        T result = caseSequentialAction(sequentialAction);
        if (result == null) result = caseAction(sequentialAction);
        if (result == null) result = caseElement(sequentialAction);
        if (result == null) result = defaultCase(theEObject);
        return result;
      }
      case EventXPackage.PARALLEL_ACTION:
      {
        ParallelAction parallelAction = (ParallelAction)theEObject;
        T result = caseParallelAction(parallelAction);
        if (result == null) result = caseAction(parallelAction);
        if (result == null) result = caseElement(parallelAction);
        if (result == null) result = defaultCase(theEObject);
        return result;
      }
      case EventXPackage.ACTION_TYPE:
      {
        ActionType actionType = (ActionType)theEObject;
        T result = caseActionType(actionType);
        if (result == null) result = defaultCase(theEObject);
        return result;
      }
      case EventXPackage.VIBRATE:
      {
        Vibrate vibrate = (Vibrate)theEObject;
        T result = caseVibrate(vibrate);
        if (result == null) result = defaultCase(theEObject);
        return result;
      }
      case EventXPackage.PLAY_SOUND:
      {
        PlaySound playSound = (PlaySound)theEObject;
        T result = casePlaySound(playSound);
        if (result == null) result = defaultCase(theEObject);
        return result;
      }
      case EventXPackage.PLAY_MEDIA:
      {
        PlayMedia playMedia = (PlayMedia)theEObject;
        T result = casePlayMedia(playMedia);
        if (result == null) result = defaultCase(theEObject);
        return result;
      }
      case EventXPackage.OPEN_BROWSER:
      {
        OpenBrowser openBrowser = (OpenBrowser)theEObject;
        T result = caseOpenBrowser(openBrowser);
        if (result == null) result = defaultCase(theEObject);
        return result;
      }
      case EventXPackage.NOTIFICATION:
      {
        Notification notification = (Notification)theEObject;
        T result = caseNotification(notification);
        if (result == null) result = defaultCase(theEObject);
        return result;
      }
      default: return defaultCase(theEObject);
    }
  }

  /**
   * Returns the result of interpreting the object as an instance of '<em>Context Aware Model</em>'.
   * <!-- begin-user-doc -->
   * This implementation returns null;
   * returning a non-null result will terminate the switch.
   * <!-- end-user-doc -->
   * @param object the target of the switch.
   * @return the result of interpreting the object as an instance of '<em>Context Aware Model</em>'.
   * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
   * @generated
   */
  public T caseContextAwareModel(ContextAwareModel object)
  {
    return null;
  }

  /**
   * Returns the result of interpreting the object as an instance of '<em>Element</em>'.
   * <!-- begin-user-doc -->
   * This implementation returns null;
   * returning a non-null result will terminate the switch.
   * <!-- end-user-doc -->
   * @param object the target of the switch.
   * @return the result of interpreting the object as an instance of '<em>Element</em>'.
   * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
   * @generated
   */
  public T caseElement(Element object)
  {
    return null;
  }

  /**
   * Returns the result of interpreting the object as an instance of '<em>Time Table</em>'.
   * <!-- begin-user-doc -->
   * This implementation returns null;
   * returning a non-null result will terminate the switch.
   * <!-- end-user-doc -->
   * @param object the target of the switch.
   * @return the result of interpreting the object as an instance of '<em>Time Table</em>'.
   * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
   * @generated
   */
  public T caseTimeTable(TimeTable object)
  {
    return null;
  }

  /**
   * Returns the result of interpreting the object as an instance of '<em>Date</em>'.
   * <!-- begin-user-doc -->
   * This implementation returns null;
   * returning a non-null result will terminate the switch.
   * <!-- end-user-doc -->
   * @param object the target of the switch.
   * @return the result of interpreting the object as an instance of '<em>Date</em>'.
   * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
   * @generated
   */
  public T caseDate(Date object)
  {
    return null;
  }

  /**
   * Returns the result of interpreting the object as an instance of '<em>Week Day Time</em>'.
   * <!-- begin-user-doc -->
   * This implementation returns null;
   * returning a non-null result will terminate the switch.
   * <!-- end-user-doc -->
   * @param object the target of the switch.
   * @return the result of interpreting the object as an instance of '<em>Week Day Time</em>'.
   * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
   * @generated
   */
  public T caseWeekDayTime(WeekDayTime object)
  {
    return null;
  }

  /**
   * Returns the result of interpreting the object as an instance of '<em>Time</em>'.
   * <!-- begin-user-doc -->
   * This implementation returns null;
   * returning a non-null result will terminate the switch.
   * <!-- end-user-doc -->
   * @param object the target of the switch.
   * @return the result of interpreting the object as an instance of '<em>Time</em>'.
   * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
   * @generated
   */
  public T caseTime(Time object)
  {
    return null;
  }

  /**
   * Returns the result of interpreting the object as an instance of '<em>Event</em>'.
   * <!-- begin-user-doc -->
   * This implementation returns null;
   * returning a non-null result will terminate the switch.
   * <!-- end-user-doc -->
   * @param object the target of the switch.
   * @return the result of interpreting the object as an instance of '<em>Event</em>'.
   * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
   * @generated
   */
  public T caseEvent(Event object)
  {
    return null;
  }

  /**
   * Returns the result of interpreting the object as an instance of '<em>Event Type</em>'.
   * <!-- begin-user-doc -->
   * This implementation returns null;
   * returning a non-null result will terminate the switch.
   * <!-- end-user-doc -->
   * @param object the target of the switch.
   * @return the result of interpreting the object as an instance of '<em>Event Type</em>'.
   * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
   * @generated
   */
  public T caseEventType(EventType object)
  {
    return null;
  }

  /**
   * Returns the result of interpreting the object as an instance of '<em>Basic Event</em>'.
   * <!-- begin-user-doc -->
   * This implementation returns null;
   * returning a non-null result will terminate the switch.
   * <!-- end-user-doc -->
   * @param object the target of the switch.
   * @return the result of interpreting the object as an instance of '<em>Basic Event</em>'.
   * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
   * @generated
   */
  public T caseBasicEvent(BasicEvent object)
  {
    return null;
  }

  /**
   * Returns the result of interpreting the object as an instance of '<em>Conditional Event</em>'.
   * <!-- begin-user-doc -->
   * This implementation returns null;
   * returning a non-null result will terminate the switch.
   * <!-- end-user-doc -->
   * @param object the target of the switch.
   * @return the result of interpreting the object as an instance of '<em>Conditional Event</em>'.
   * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
   * @generated
   */
  public T caseConditionalEvent(ConditionalEvent object)
  {
    return null;
  }

  /**
   * Returns the result of interpreting the object as an instance of '<em>Room Event</em>'.
   * <!-- begin-user-doc -->
   * This implementation returns null;
   * returning a non-null result will terminate the switch.
   * <!-- end-user-doc -->
   * @param object the target of the switch.
   * @return the result of interpreting the object as an instance of '<em>Room Event</em>'.
   * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
   * @generated
   */
  public T caseRoomEvent(RoomEvent object)
  {
    return null;
  }

  /**
   * Returns the result of interpreting the object as an instance of '<em>Close By</em>'.
   * <!-- begin-user-doc -->
   * This implementation returns null;
   * returning a non-null result will terminate the switch.
   * <!-- end-user-doc -->
   * @param object the target of the switch.
   * @return the result of interpreting the object as an instance of '<em>Close By</em>'.
   * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
   * @generated
   */
  public T caseCloseBy(CloseBy object)
  {
    return null;
  }

  /**
   * Returns the result of interpreting the object as an instance of '<em>Transition Area</em>'.
   * <!-- begin-user-doc -->
   * This implementation returns null;
   * returning a non-null result will terminate the switch.
   * <!-- end-user-doc -->
   * @param object the target of the switch.
   * @return the result of interpreting the object as an instance of '<em>Transition Area</em>'.
   * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
   * @generated
   */
  public T caseTransitionArea(TransitionArea object)
  {
    return null;
  }

  /**
   * Returns the result of interpreting the object as an instance of '<em>Event Attributes</em>'.
   * <!-- begin-user-doc -->
   * This implementation returns null;
   * returning a non-null result will terminate the switch.
   * <!-- end-user-doc -->
   * @param object the target of the switch.
   * @return the result of interpreting the object as an instance of '<em>Event Attributes</em>'.
   * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
   * @generated
   */
  public T caseEventAttributes(EventAttributes object)
  {
    return null;
  }

  /**
   * Returns the result of interpreting the object as an instance of '<em>Action</em>'.
   * <!-- begin-user-doc -->
   * This implementation returns null;
   * returning a non-null result will terminate the switch.
   * <!-- end-user-doc -->
   * @param object the target of the switch.
   * @return the result of interpreting the object as an instance of '<em>Action</em>'.
   * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
   * @generated
   */
  public T caseAction(Action object)
  {
    return null;
  }

  /**
   * Returns the result of interpreting the object as an instance of '<em>Simple Action</em>'.
   * <!-- begin-user-doc -->
   * This implementation returns null;
   * returning a non-null result will terminate the switch.
   * <!-- end-user-doc -->
   * @param object the target of the switch.
   * @return the result of interpreting the object as an instance of '<em>Simple Action</em>'.
   * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
   * @generated
   */
  public T caseSimpleAction(SimpleAction object)
  {
    return null;
  }

  /**
   * Returns the result of interpreting the object as an instance of '<em>Sequential Action</em>'.
   * <!-- begin-user-doc -->
   * This implementation returns null;
   * returning a non-null result will terminate the switch.
   * <!-- end-user-doc -->
   * @param object the target of the switch.
   * @return the result of interpreting the object as an instance of '<em>Sequential Action</em>'.
   * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
   * @generated
   */
  public T caseSequentialAction(SequentialAction object)
  {
    return null;
  }

  /**
   * Returns the result of interpreting the object as an instance of '<em>Parallel Action</em>'.
   * <!-- begin-user-doc -->
   * This implementation returns null;
   * returning a non-null result will terminate the switch.
   * <!-- end-user-doc -->
   * @param object the target of the switch.
   * @return the result of interpreting the object as an instance of '<em>Parallel Action</em>'.
   * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
   * @generated
   */
  public T caseParallelAction(ParallelAction object)
  {
    return null;
  }

  /**
   * Returns the result of interpreting the object as an instance of '<em>Action Type</em>'.
   * <!-- begin-user-doc -->
   * This implementation returns null;
   * returning a non-null result will terminate the switch.
   * <!-- end-user-doc -->
   * @param object the target of the switch.
   * @return the result of interpreting the object as an instance of '<em>Action Type</em>'.
   * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
   * @generated
   */
  public T caseActionType(ActionType object)
  {
    return null;
  }

  /**
   * Returns the result of interpreting the object as an instance of '<em>Vibrate</em>'.
   * <!-- begin-user-doc -->
   * This implementation returns null;
   * returning a non-null result will terminate the switch.
   * <!-- end-user-doc -->
   * @param object the target of the switch.
   * @return the result of interpreting the object as an instance of '<em>Vibrate</em>'.
   * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
   * @generated
   */
  public T caseVibrate(Vibrate object)
  {
    return null;
  }

  /**
   * Returns the result of interpreting the object as an instance of '<em>Play Sound</em>'.
   * <!-- begin-user-doc -->
   * This implementation returns null;
   * returning a non-null result will terminate the switch.
   * <!-- end-user-doc -->
   * @param object the target of the switch.
   * @return the result of interpreting the object as an instance of '<em>Play Sound</em>'.
   * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
   * @generated
   */
  public T casePlaySound(PlaySound object)
  {
    return null;
  }

  /**
   * Returns the result of interpreting the object as an instance of '<em>Play Media</em>'.
   * <!-- begin-user-doc -->
   * This implementation returns null;
   * returning a non-null result will terminate the switch.
   * <!-- end-user-doc -->
   * @param object the target of the switch.
   * @return the result of interpreting the object as an instance of '<em>Play Media</em>'.
   * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
   * @generated
   */
  public T casePlayMedia(PlayMedia object)
  {
    return null;
  }

  /**
   * Returns the result of interpreting the object as an instance of '<em>Open Browser</em>'.
   * <!-- begin-user-doc -->
   * This implementation returns null;
   * returning a non-null result will terminate the switch.
   * <!-- end-user-doc -->
   * @param object the target of the switch.
   * @return the result of interpreting the object as an instance of '<em>Open Browser</em>'.
   * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
   * @generated
   */
  public T caseOpenBrowser(OpenBrowser object)
  {
    return null;
  }

  /**
   * Returns the result of interpreting the object as an instance of '<em>Notification</em>'.
   * <!-- begin-user-doc -->
   * This implementation returns null;
   * returning a non-null result will terminate the switch.
   * <!-- end-user-doc -->
   * @param object the target of the switch.
   * @return the result of interpreting the object as an instance of '<em>Notification</em>'.
   * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
   * @generated
   */
  public T caseNotification(Notification object)
  {
    return null;
  }

  /**
   * Returns the result of interpreting the object as an instance of '<em>EObject</em>'.
   * <!-- begin-user-doc -->
   * This implementation returns null;
   * returning a non-null result will terminate the switch, but this is the last case anyway.
   * <!-- end-user-doc -->
   * @param object the target of the switch.
   * @return the result of interpreting the object as an instance of '<em>EObject</em>'.
   * @see #doSwitch(org.eclipse.emf.ecore.EObject)
   * @generated
   */
  @Override
  public T defaultCase(EObject object)
  {
    return null;
  }

} //EventXSwitch
